<?php include("header.php"); ?>

      <table width="778" border="0" align="center" cellpadding="5">
	  
	  <?php
	  
	    $categories = DAOFactory::getCategorymasterDAO()->queryAllOrderBy('Position');

		for($i=0;$i<count($categories) && $i<10;$i++){
			$row = $categories[$i];
			$i++;
			?>
			<tr>
            <td width="340"><div align="left">
			<span class="style8"><?php echo "<a style='text-decoration:none' href='".$base."/categories/".$row->categoryMasterId."/0/".$row->url.".html'>".$row->categoryName."</a>" ?></span><br>
            <span class="style11"><?php echo $row->categoryDescription ?></span><br>
            &nbsp;</div></td>
			<td width="84"><div align="left"></div></td>
		   
		   <?php 
		   	if($i<count($categories)){
				$row = $categories[$i];
				?>
				
				<td width="340"><div align="left">
				<span class="style8"><?php echo "<a style='text-decoration:none' href='".$base."/categories/".$row->categoryMasterId."/0/".$row->url.".html'>".$row->categoryName."</a>" ?></span><br>
				<span class="style11"><?php echo $row->categoryDescription ?></span><br>
				&nbsp;</div></td>
			   	</tr>
			<?php 		
		    
			}else{   		
		   		?>
				<tr>
				<td width="340"><div align="left">
				<span class="style8">&nbsp;</span><br>
				<span class="style11">&nbsp;</span><br>
				&nbsp;</div></td>
			   	</tr>
				<?php
		   } 		   
		  
		}

		?>
          <tr>
            <td width="340"><br>
            &nbsp;</td>
            <td width="84">&nbsp;</td>
            <td width="340"><br>
            &nbsp;</td>
          </tr>
        </table>
		
<?php include("footer.php"); ?>
